/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package Server;

import java.applet.Applet;
import java.io.IOException;
import java.net.Socket;
import java.util.logging.Level;
import java.util.logging.Logger;

/**
 *
 * @author Lucas
 */
public class Client extends Connection{
    
    private final int poort = 1234;

    public Client(Applet a, String naam) throws IOException{
        super(new Socket(a.getCodeBase().getHost(), 1234),naam);
    }

    public String getStatus(){
        
        while(!isConnected()){
            String g = null;
            try {
                g = receive();
            } catch (IOException ex) {
                Logger.getLogger(Client.class.getName()).log(Level.SEVERE, null, ex);
            } catch (ClassNotFoundException ex) {
                Logger.getLogger(Client.class.getName()).log(Level.SEVERE, null, ex);
            }
          return g;
        }
       return null;
    }

}
